import 'package:json_annotation/json_annotation.dart';

part 'resource.g.dart';

@JsonSerializable()
class ResourceData {
  String resourcesName;
  String releaseName;
  String resourcesType;
  String microFormat;
  String createTime;
  String sowingSum;
  String resourcesUrlLow;
  String resourcesUrlHigh;
  String resourcesUrlSuper;
  String downloadUrl;
  String subject;
  String isAllowDown;
  String resourcesId;
  String duration;
  String pageIndex;
  String pageSize;
  String total;
  String selectTime;
  String fileSize;

  ResourceData(
      {this.resourcesName,
      this.releaseName,
      this.resourcesType,
      this.microFormat,
      this.createTime,
      this.sowingSum,
      this.resourcesUrlLow,
      this.resourcesUrlHigh,
      this.resourcesUrlSuper,
      this.downloadUrl,
      this.subject,
      this.isAllowDown,
      this.resourcesId,
      this.duration,
      this.pageIndex,
      this.pageSize,
      this.total,
      this.fileSize,
      this.selectTime});

  //反序列化
  factory ResourceData.fromJson(Map<String, dynamic> json) =>
      _$ResourceDataFromJson(json);

//序列化
  Map<String, dynamic> toJson() => _$ResourceDataToJson(this);
}
